package com.woniuxy.entity;

import com.woniuxy.entity.dto.PowerUserDTO;
import com.woniuxy.entity.dto.YiDTO;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.beans.BeanUtils;

/**
 * @program: tsm
 * @description:
 * @create: 2024-10-16 21:13
 **/
@Data
@AllArgsConstructor
@NoArgsConstructor
public class PowerUser {
    private Integer id;
    private String username;
    private String password;
    private String realName;
    private String email;
    private String phone;
    private Integer locked;
    private String createdTime;
    private String imgSrc;
    private Integer createdId;
    public PowerUser(PowerUserDTO powerUserDTO){
        //把dto的属性值赋给当前对象
        //参数1：数据来源
        //参数2：目标对象
        BeanUtils.copyProperties(powerUserDTO,this);
    }
}
